package com.xiaoshuidi.cloud.module.report.convert.ajreport;

import com.xiaoshuidi.cloud.framework.common.pojo.PageResult;
import com.xiaoshuidi.cloud.module.report.controller.ajreport.vo.*;
import com.xiaoshuidi.cloud.module.report.dal.DO.report.ReportRoomReserveDO;
import org.mapstruct.Mapper;
import org.mapstruct.Mapping;
import org.mapstruct.factory.Mappers;

import java.util.List;

/**
 * 台账报表 转换类
 */
@Mapper
public interface ReportRoomReverseConvert {

    ReportRoomReverseConvert INSTANCE = Mappers.getMapper(ReportRoomReverseConvert.class);

    @Mapping(source = "checkInDate", target = "checkInDate", dateFormat = "yyyy-MM-dd")
    @Mapping(source = "expirationDate", target = "expirationDate", dateFormat = "yyyy-MM-dd")
    ReportRoomReserveRespVO convert(ReportRoomReserveDO infoDO);



    PageResult<ReportRoomReserveRespVO> convertPage(PageResult<ReportRoomReserveDO> page);

    List<ReportRoomReserveExportVO> convertList(List<ReportRoomReserveDO> list);

}

